package com.qdxwx.data.mapper.manager;

import com.qdxwx.common.page.PageRequest;
import com.qdxwx.models.manager.Manager;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 用户表 数据层
 * Qdx NetSchool Platform
 * @author qdxwx
 * @updateTime 2022/5/25
 * @description
 */
@Repository
public interface ManagerMapper
{

    List<Manager> selectList(@Param("e") Manager manager, @Param("page") PageRequest page);

    int selectCount(@Param("e") Manager manager);

    List<Manager> selectAllocatedList(@Param("e") Manager manager, @Param("page") PageRequest page);

    long selectAllocatedCount(@Param("e") Manager manager);

    List<Manager> selectUnallocatedList(@Param("e") Manager manager, @Param("page") PageRequest page);

    long selectUnallocatedCount(@Param("e") Manager manager);

    Manager selectManagerByLoginName(String managerName);

    Manager selectManagerByMobile(String mobile);

    Manager selectManagerById(int managerId);

    int deleteById(long ids);

    int updateManager(Manager manager);

    int insertManager(Manager manager);

    int checkLoginName(String loginName);

    int checkMobile(String mobile);

    int updateDisabled(Manager manager);

    int updateCombine(long userId1, long userId2);
}
